import { createRouter, createWebHashHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'
// import AboutView from '../views/AboutView.vue'
// import FiguresView from '../views/FiguresView.vue'
// import DiscussionView from '../views/DiscussionView.vue'
// import RelicsView from '../views/RelicsView.vue'

const routes = [{
        path: '/',

        name: 'index',
        component: {},
        // redirect: '/landing',
        redirect: '/home',
    }, {
        path: '/home',
        name: 'home',
        component: HomeView,
    },
    {
        path: '/geolocation',
        name: 'geolocation',
        // route level code-splitting
        // this generates a separate chunk (about.[hash].js) for this route
        // which is lazy-loaded when the route is visited.
        component: () =>
            import ( /* webpackChunkName: "about" */ '../views/GeolocationView.vue')
    },
    {
        path: '/figures',
        name: 'figures',
        // route level code-splitting
        // this generates a separate chunk (about.[hash].js) for this route
        // which is lazy-loaded when the route is visited.
        component: () =>
            import ( /* webpackChunkName: "about" */ '../views/FiguresView.vue')
    },
    {
        path: '/relics',
        name: 'relics',
        // route level code-splitting
        // this generates a separate chunk (about.[hash].js) for this route
        // which is lazy-loaded when the route is visited.
        component: () =>
            import ( /* webpackChunkName: "about" */ '../views/RelicsView.vue')
    },
    {
        path: '/discussion',
        name: 'discussion',
        // route level code-splitting
        // this generates a separate chunk (about.[hash].js) for this route
        // which is lazy-loaded when the route is visited.
        component: () =>
            import ( /* webpackChunkName: "about" */ '../views/DiscussionView.vue')
    },
    {
        path: '/landing',
        name: 'landing',
        component: () =>
            import ( /* webpackChunkName: "about" */ '../views/LandingView.vue')
    },
]

const router = createRouter({
    mode: 'hash',
    history: createWebHashHistory(process.env.BASE_URL),
    routes
})

export default router